package com.orange.community.dao;

import com.orange.community.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;

/**
 * @author GaryGyp
 * @Description:
 *      用户
 */
@Mapper
public interface UserMapper {

    //根据用户id查找
    User selectById(int id);
    //根据用户名查找
    User selectByName(String username);
    //根据邮箱查找
    User selectByEmail(String email);
    //增加一个用户
    int insertUser(User user);
    //修改一个用户
    int updateStatus(int id, int status);
    //更新用户头像
    int updateHeader(int id, String headerUrl);
    //更新用户密码
    int updatePassward(int id, String password);

}
